package com.cskaoyan.service;

import com.cskaoyan.bean.baseresultVO.BaseParam;
import com.cskaoyan.bean.domain.Goods;
import com.cskaoyan.bean.goods.BasePageData;
import com.cskaoyan.bean.goods.CatAndBrandVo;
import com.cskaoyan.bean.goods.GoodsAddBO;
import com.cskaoyan.bean.goods.GoodsEchoVo;

/**
 * @BelongProject: mall35th
 * @BelongPackage: com.cskaoyan.service
 * @Author: zijin
 * @Createtime: 2021-11-30 星期二 09:15
 * @Description: todo
 */
public interface GoodsService {
    /**
     * 根据商品id、商品编号、商品名称  模糊查询商品
     * @param goodsId
     * @param goodsSn
     * @param name
     * @param pageParams
     * @return
     */
    BasePageData queryGoodsByCondition(Integer goodsId, String goodsSn, String name, BaseParam pageParams);

    GoodsEchoVo queryDetails(Integer id);

    /**
     * 查询品牌列表和商品类型
     * @return
     */
    CatAndBrandVo queryCatgoryAndBrand();

    /**
     * 新增商品信息，更新商品相关表信息
     * @return
     */
    boolean createGoods(GoodsAddBO goodsAddBO);

    boolean updateGoods(GoodsAddBO goodsAddBO);

    /**
     * 删除商品，逻辑删除
     * @param goods
     * @return
     */
    boolean deleteGoods(Goods goods);

    /**
     * zhiMing 根据商品id返回商品信息
     */
    Goods queryDetailById(Integer id);
}
